<!DOCTYPE html>
<html>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ page contentType="text/html;charset=UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://www.springframework.org/tags" prefix="s" %>
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form" %>
<%@ taglib uri="/auth-tags" prefix="auth" %>
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<title>新增或修改功能菜单</title>
</head>


<body>
<style>
	.controls{text-align:left;}
	.yc_input_border input{ border-radius:0px;}
	#addForm font{
		margin-left:5px;
		font-size:20px;
		float:left;
		line-height:24px;
	}
</style>
	<form:form id="addForm" method="post" modelAttribute="beanForm" cssClass="form-horizontal form-offset-top">
		<form:hidden id="functionId" path="functionId"/>
		<form:hidden id="parentFuncId" path="parentFuncId"/>
		
	 	<div class="control-group clearfix">
	 		<form:label cssClass="userLabel fl" for="functionName" path="functionName" >功能名称:</form:label>
			<form:input id="functionName" path="functionName" style="width:400px;margin-right:3px"  check-type="required" cssClass="userInput fl"/>
			<font style="color:#f00;">*</font>
		</div>
		
		<div class="control-group clearfix">
			<form:label cssClass="userLabel fl" for="functionCode" path="functionCode" >功能编码:</form:label>
			<form:input id="functionCode" path="functionCode" style="width:400px;margin-right:3px" check-type="required" cssClass="userInput fl"/>
			<font style="color:#f00;">*</font>
		</div>
			
		<div class="control-group clearfix">
			<form:label cssClass="userLabel fl" for="assemblyName" path="assemblyName" >URL地址:</form:label>
			<form:textarea cssClass="userInput fl" id="assemblyName" path="assemblyName" rows="50" cols="50" style="width:400px; height:50px;"/>
			<span class="help-inline"></span>
		</div>
					
		<div class="control-group clearfix"  style="display: none">
			<form:label cssClass="userLabel fl" for="functionImg" path="functionImg" >功能图标:</form:label>
			<form:input id="functionImg" path="functionImg" style="width:400px;" cssClass="userInput fl"/>
			<font style="color:#f00;">*</font>
		</div>
		
		<div class="control-group clearfix">
			<form:label cssClass="userLabel fl" for="functionType" path="functionType" >类型:</form:label>
			<form:select id="functionType"  path="functionType" style="width:400px;" class="userInput fl">
				<form:option value="MENU" >菜单</form:option>
				<form:option value="RESOURCE" >资源</form:option>
			</form:select>
		</div>
				
		<div class="control-group clearfix">
			<form:label cssClass="userLabel fl" for="ordering" path="ordering" >显示序号:</form:label>
			<form:input id="ordering" path="ordering" style="width:400px;" check-type="required number"  cssClass="userInput fl"/>
				<font style="color:#f00;">*</font>
		</div>
		
		<div class="control-group clearfix">
			<form:label cssClass="userLabel fl" for="state" path="state" >状态:</form:label>
			<form:select id="state"  path="state" style="width:400px;" class="userInput fl">
				<form:option value="ENABLED" >启用</form:option>
				<form:option value="DISABLED" >停用</form:option>
			</form:select>		
		</div>
		
		<div class="control-group clearfix">
			<form:label cssClass="userLabel fl" for="remark" path="remark" >说明:</form:label>
			<form:textarea class="userInput fl" id="remark" path="remark" rows="50" cols="50" style="width:400px; height:80px;"/>
				<span class="help-inline"></span>
		</div>
		
		<div class="control-group ">
			<a class="userBtn db fl" id="addFirstBtn" onclick="addRootData();" href="javascript:;">增加顶级</a>
            <a class="userBtn db fl" id="addBtn" onclick="addData();" href="javascript:;">增加下级</a>
            <a class="userBtn db fl" id="deleteBtn" onclick="deleteData();" href="javascript:;">删除</a>
            <a class="userBtn db fl" id="saveBtn" onclick="if(saveData()==false) return false;" href="javascript:;">保存</a>
            <a class="userBtn db fl" id="resetBtn" href="javascript:;">重置</a>
		</div>
	</form:form>

</body>
</html>	